package com.example.attempt.service;

import com.example.attempt.entity.Appeal;
import com.example.attempt.entity.AppealStu;
import com.example.attempt.entity.Grade;

import java.util.List;

public interface GradeService {
    public List<Grade> queryAll();
    public Grade getGradesByHidSid(int hid, String sid); //查找某作业所有成绩
    public int getNum(int hid, double grade);//获取某成绩段人数
    public int getDown60Num(int hid);
    public double getAverage(int hid); //获取某次作业的平均成绩
    public List<Appeal> getAppeal(String cid);
    public List<AppealStu> getStuAppeal(String sid); //学生获取自己的申诉列表
    public int updateGradeS1(int submitId, double grade);
    public int updateGradeS2(int submitId, double grade);
    public int updateGradeS3(int submitId, double grade);
    public int updateGradeT(int submitId, double grade);
    public int updateGradeA(int submitId, double grade);
    public int updateGrade(int hid, String sid, double grade);//计算总成绩
    public int modifyGrade(int hid, String sid, double grade); //教师修改成绩
    public int updateAppeal(int hid, String sid, int isAppeal, String reason);
    public int refuseAppeal(int submitId, int isAppeal, String refuseReason);
    public int addGrade(Grade grade);
}
